define(['jquery', 'datatables.net-bs', 'adminlte.demo', 'public/js/paging', 'layer', 'jquery.zclip'], function($, datatablesNetBs, adminlteDemo, Paging, Layer){
    'use strict';

    var Page = {}, DOM;

    function init(){
        DOM = {
            example1: $('#example1'),
            btnCopy: $('.btnCopy')
        }
    }

    Page.main = function(){
        init();
        handleEvent();
    }

    function handleEvent(){
        DOM.example1.DataTable({
            'paging': false,
            'autoWidth': true,
            'searching': false,
            'info': false,
        });

        // 复制链接
        DOM.btnCopy.zclip({
	        path: _base + '/resource/public/plugin/jquery/zclip/ZeroClipboard.swf',
	        copy: function(){//复制内容
	        	console.log('cccc');
	            return $(this).data('url');
	        },
	        afterCopy: function(){//复制成功
	        	Layer.msg('复制成功');
	        }
	    });
    }

    return Page;
});